#include <QApplication>
#include <QThread>
#include <QDebug>
#include "receiverthread.h"
#include "senderthread.h"

int main(int argc, char* argv[])
{
    QApplication app(argc, argv);

    ReceiverThread receiver;
    SenderThread sender;

    QObject::connect(&sender, &SenderThread::sendMsg,
                     &receiver, &ReceiverThread::receMsg);

    qDebug() << "Main Thread id: "
             << QThread::currentThreadId();
    receiver.start();
    sender.start();

    return app.exec();
}
